import {GETMOVIELIST} from '../constant/movieConst'
const init = {movieList:[]}

export default function movieReducer(prevState=init,action){
  const {type,data} = action 
  // console.log(type,data,'movielistdata');
  switch (type) {
    case GETMOVIELIST:
      return {...prevState,movieList:data}
  }

  return prevState
}